<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      var radius = prompt("请问圆的半径为多少");
      var zhouchang = 2 * Math.PI * radius;
      var mianji = Math.PI * radius * radius;
      console.log(
        `圆的半径是${radius},周长为${zhouchang.toFixed(
          2
        )},面积为${mianji.toFixed(2)}`
      );
    </script>
  </body>
</html>
